package com.xfcy.content.api;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.servlet.ModelAndView;

/**
 * @author 晓风残月Lx
 * @date 2023/6/20 22:40
 */
@Controller
public class FreemarkerController {

    @GetMapping("/testfreemarker")
    public ModelAndView test() {

        ModelAndView modelAndView = new ModelAndView();

        modelAndView.addObject("name", "小明");

        modelAndView.setViewName("test");

        return modelAndView;
    }
}
